//
// Decompiled by Jadx - 352ms
//
package gc;

import android.app.Activity;
import android.text.TextUtils;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.LinearLayout;
import android.widget.TextView;
import androidx.activity.b;
import androidx.constraintlayout.widget.i;
import cc.f;
import fh.a;
import fi.m;
import fi.w;
import fn.j;
import fn.y;
import fo.c;
import java.lang.reflect.Proxy;
import org.luckypray.dexkit.query.matchers.FieldMatcher;
import org.luckypray.dexkit.result.FieldData;
import r.e;

public final class ci {
    public final Object a;
    public final FieldData b;
    public String c;

    public ci(Activity activity, double d, double d2) {
        w wVar = new w(activity);
        this.b = c.p(FieldMatcher.create().type("com.baidu.mapapi.search.geocode.ReverseGeoCodeResult$AddressComponent").declaredClass("com.baidu.mapapi.search.geocode.ReverseGeoCodeResult"));
        View inflate = LayoutInflater.from(activity).inflate(-2113142747, (ViewGroup) null, false);
        int i = 0x7f820058;
        LinearLayout linearLayout = (LinearLayout) i.cg(0x7f820058, inflate);
        if (linearLayout != null) {
            i = 0x7f820096;
            TextView textView = (TextView) i.cg(0x7f820096, inflate);
            if (textView != null) {
                i = 0x7f820098;
                TextView textView2 = (TextView) i.cg(0x7f820098, inflate);
                if (textView2 != null) {
                    i = 0x7f82009f;
                    TextView textView3 = (TextView) i.cg(0x7f82009f, inflate);
                    if (textView3 != null) {
                        i = 0x7f8200a0;
                        TextView textView4 = (TextView) i.cg(0x7f8200a0, inflate);
                        if (textView4 != null) {
                            f fVar = new f((LinearLayout) inflate, linearLayout, textView, textView2, textView3, textView4);
                            Object bl = j.bl("com.baidu.mapapi.map.MapView", new Object[]{activity});
                            ((LinearLayout) fVar.f).addView((ViewGroup) bl);
                            float f = 25;
                            e.d(-2113535903, f, (TextView) fVar.e);
                            e.d(-2113535903, f, (TextView) fVar.d);
                            ((TextView) fVar.d).setText("取消");
                            ((TextView) fVar.d).setOnClickListener(new m(3, wVar));
                            ((TextView) fVar.e).setText("复制地址");
                            ((TextView) fVar.e).setOnClickListener(new a(3, this));
                            wVar.bj(fi.e.VIEW);
                            wVar.ar = fVar.h();
                            Object aa = j.aa(bl, "getMap");
                            wVar.bk();
                            Object bl2 = j.bl("com.baidu.mapapi.search.geocode.GeoCoder", new Object[0]);
                            Object newProxyInstance = Proxy.newProxyInstance(y.by.getClassLoader(), new Class[]{j.ak("com.baidu.mapapi.search.geocode.OnGetGeoCoderResultListener")}, new a(this, fVar, aa, activity, bl2));
                            Object bl3 = j.bl("com.baidu.mapapi.model.LatLng", new Object[]{Double.valueOf(d), Double.valueOf(d2)});
                            this.a = bl3;
                            j.ab(bl2, "setOnGetGeoCodeResultListener", new Object[]{newProxyInstance});
                            j.ab(bl2, "reverseGeoCode", new Object[]{j.ab(j.ab(j.ab(j.bl("com.baidu.mapapi.search.geocode.ReverseGeoCodeOption", new Object[0]), "location", new Object[]{bl3}), "newVersion", new Object[]{1}), "radius", new Object[]{500})});
                            return;
                        }
                    }
                }
            }
        }
        throw new NullPointerException("Missing required view with ID: ".concat(inflate.getResources().getResourceName(i)));
    }

    public static String d(ci ciVar, String str) {
        ciVar.getClass();
        if (TextUtils.isEmpty(str)) {
            return "";
        }
        return b.x(str, " ");
    }
}
